//
//  AllOfHotShopsCell.m
//  project_delicious
//
//  Created by 章历杰 on 15/3/25.
//  Copyright (c) 2015年 lanou3g.com 蓝鸥科技. All rights reserved.
//

#import "AllOfHotShopsCell.h"

@implementation AllOfHotShopsCell
- (void)dealloc
{
    [_mDic release];
    [_shop release];
    [super dealloc];
}
-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.shop = [[HotShop alloc] initWithFrame:self.contentView.bounds];
//        _shop.layer.borderWidth = 1;
//        _shop.layer.borderColor = [[UIColor lightGrayColor] CGColor];
//        _shop.layer.cornerRadius = 5;
        [self.contentView addSubview:_shop];
        [_shop release];
    }
    return self;
}

- (void)layoutSubviews
{
    [super layoutSubviews];

}

- (void)setMDic:(NSMutableDictionary *)mDic
{
    if (_mDic != mDic) {
        [_mDic release];
        _mDic = [mDic retain];
    }
    
    
    _shop.hotShopName.text = [mDic objectForKey:@"name"];
    NSString *str = [NSString stringWithFormat:@"%ld", (long)[[mDic objectForKey:@"arg_spend"] integerValue]];
    _shop.hotShopFee.text = [NSString stringWithFormat:@"￥%@/人", str];
    _shop.hotShopLocation.text = [mDic objectForKey:@"address"];
    
    
}
- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
